import request from '@/config/request'
import type { StudentSearchForm, StudentUpdateForm, StudyLogParam, LessonStudyParam } from '@/config/forms'

export default {
    getList: (form : StudentSearchForm) => request.post('/backend/students', form),
    getItem: (accountId : number) => request.get(`/backend/students/${accountId}`),
    update: (accountId: number, form : StudentUpdateForm) => request.post(`/backend/students/${accountId}`, form),
    getStudyLog: (params: StudyLogParam) => request.get('/backend/educations/student', { params }),
    getLessonStudyLog: (params: LessonStudyParam) => request.get('/backend/educations/student/logs', {params}),
}